class Photo < Asset
  has_attached_file :data,
                    :url  => "/assets/photos/:id/:style_:basename.:extension",
                    :path => ":rails_root/public/assets/photos/:id/:style_:basename.:extension",
	                  :styles => { :content => '700>', :thumb => '62x63', :structure=>'534x237#', :coach=>'188x241#', :coach_small=>'96x123#', :gallery=>'162x107#' }
	
	validates_attachment_size :data, :less_than=>4.megabytes

  validates_numericality_of :position, :only_integer => true
end
